Skip to content

feat(cli): motion command — surface GSAP motion + 3D onion-skin --shot#1603

Open
miguel-heygen wants to merge 10 commits into
mainfrom
feat/keyframes-cli
Open

feat(cli): motion command — surface GSAP motion + 3D onion-skin --shot#1603
miguel-heygen wants to merge 10 commits into
mainfrom
feat/keyframes-cli

Conversation

@miguel-heygen

@miguel-heygen miguel-heygen commented Jun 19, 2026

Copy link
Copy Markdown
Collaborator

Problem

The PR originally introduced the motion-surfacing tool as hyperframes keyframes, but the intended product/skill name is now motion. Leaving the command, implementation files, and skill package named keyframes makes the public CLI surface feel narrower than what the tool actually does: inspect, debug, and improve rendered motion.

What this fixes

  • Exposes the CLI as npx hyperframes motion.
  • Renames the command implementation from keyframes*.ts to motion*.ts while preserving the keyframe data model inside the command where that term is still accurate.
  • Renames the shipped skill from hyperframes-keyframes to hyperframes-motion.
  • Expands the skill from a command reference into a motion-design workflow: reading motion, 3D angle verification, layered GSAP motion, one-shot reference reproduction, diagnostic checks, and eval-derived craft guidance.

Root cause

The original command name described one implementation detail: surfacing GSAP keyframes. The tool has grown into a broader motion-debugging loop with onion-skin screenshots, true-3D sampling, composed ancestor motion, multi-stroke traces, and motion-design critique. The source layout and skill name needed to match that broader behavior.

Verification

Local checks

  • git diff --cached --check
  • bunx oxfmt --check packages/cli/src/cli.ts packages/cli/src/commands/motion.ts packages/cli/src/commands/motion.test.ts packages/cli/src/commands/motionShot.ts packages/cli/src/commands/motionShotLayout.ts packages/cli/src/commands/motionShotLayout.test.ts
  • bunx oxlint packages/cli/src/cli.ts packages/cli/src/commands/motion.ts packages/cli/src/commands/motion.test.ts packages/cli/src/commands/motionShot.ts packages/cli/src/commands/motionShotLayout.ts packages/cli/src/commands/motionShotLayout.test.ts
  • bun run lint:skills
  • bun run test -- src/commands/motion.test.ts src/commands/motionShotLayout.test.ts from packages/cli (22 tests passed)
  • bun run typecheck from packages/cli
  • bun packages/cli/src/cli.ts motion --help

Pre-commit also ran lint, format, fallow, and typecheck successfully for the committed changes.

Browser verification

No browser app flow is affected by this CLI/skill rename. The user-visible smoke path is the CLI help output for hyperframes motion, verified locally.

Notes

  • The branch name is still feat/keyframes-cli; the PR title/body and code now use the motion product name.
  • Unrelated local package.json, bun.lock, and shots/ changes were left unstaged and were not pushed.

…shot

Read-then-edit-source tool for GSAP motion. Surfaces every tween's keyframes as
data; --shot renders a true-3D onion-skin of the real element (samples the live
timeline at N steps; rotation/scale/opacity/colour/3D, not just x/y) for visual
self-verify. Multi-stroke pen-up traces for holed/detached shapes. Framing:
--layout strip (filmstrip), --from/--to (time window), --no-fit, --angle (orbit
camera). Pure geometry+SVG in keyframesShotLayout.ts (unit-tested). Ships the
hyperframes-keyframes skill. Depends only on what's already in main.
Comment thread packages/cli/src/commands/motion.ts Fixed
One viewpoint hides depth — a flip reads as a static stack head-on, a tumble looks
flat. Mandate ≥3 angles (front+top+side/iso) for any 3D motion, and --layout strip
for in-place/overlapping motion.
…t-write-wins)

When a brief has channels independent in phase or rate (orbit + axial spin, path +
flap, bounce + roll), layer them across nested elements (parent=trajectory,
child=secondary) instead of cramming one tween; --shot --selector the leaf shows
the composition.
A nested child's rendered motion is composed with its animated ancestors, but the
per-element text/JSON surface showed only the child's own tween — hiding a parent's
path (a judge/agent reading text would miss it). Now each tween is annotated with
its animated DOM ancestors and their motion EXTENT (per-property min..max, so a
closed loop still reveals its travel).
…aligned squash vs spin, heading=tangent, per-channel check) + composed-surface note
@miguel-heygen miguel-heygen changed the title feat(cli): keyframes command — surface GSAP motion + 3D onion-skin --shot feat(cli): motion command — surface GSAP motion + 3D onion-skin --shot Jun 22, 2026
let projectName: string;
let projectDir: string | undefined;
if (raw && raw.endsWith(".html") && existsSync(raw) && statSync(raw).isFile()) {
comps = [surfaceComposition(readFileSync(raw, "utf-8"), basename(raw), raw)];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants